Skip to main content

Webhook: TASK_EDITED

Description

The TASK_EDITED webhook is triggered whenever an existing task is modified. This notification allows systems or users to keep track of changes to task details in real-time.


Request Format

The webhook is sent as an HTTP POST request with the following payload:

{
"entityId": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"type": "TASK_EDITED",
"createdAt": "2024-12-16T09:50:29.775Z",
"data": {
"operation": "UPDATE",
"current": {
"id": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"organizationId": "9864d894-699a-4a00-8d4c-ae181215d721",
"locationId": "27b732ee-5921-475f-acd7-137fc4d5aa0f",
"startAt": "2024-12-16T09:00:00.000Z",
"endAt": "2024-12-16T13:00:00.000Z",
"name": "Task 2",
"assigneeIds": [
"6ad1a95b-ea50-4e23-8495-ef82900ca98d"
],
"recurrenceRule": null
},
"previous": {
"id": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"organizationId": "9864d894-699a-4a00-8d4c-ae181215d721",
"locationId": "27b732ee-5921-475f-acd7-137fc4d5aa0f",
"startAt": "2024-12-16T09:00:00.000Z",
"endAt": "2024-12-16T11:15:00.000Z",
"name": "Task 2",
"assigneeIds": [
"6ad1a95b-ea50-4e23-8495-ef82900ca98d"
],
"recurrenceRule": null
}
}
}

Key Properties

Top-Level Properties

  • entityId: Unique identifier for the modified task.
  • type: Specifies the type of webhook (TASK_EDITED).
  • createdAt: Timestamp indicating when the webhook was triggered (in ISO 8601 format).
  • data: Contains details about the modification.

Data Section

  • operation: Indicates the type of operation performed on the task (UPDATE).
  • current: Reflects the task's updated properties.
  • previous: Reflects the task's properties before the update.

Task Properties

These properties are present in both the current and previous sections:

  • id: Unique identifier for the task.
  • organizationId: ID of the organization associated with the task.
  • locationId: ID of the location where the task is assigned.
  • startAt: Start time of the task in ISO 8601 format.
  • endAt: End time of the task in ISO 8601 format.
  • name: Name of the task.
  • assigneeIds: List of user IDs assigned to the task.
  • recurrenceRule: Details about task recurrence (if applicable).

Response Example

A typical response payload confirming receipt of the webhook:

{
"entityId": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"type": "TASK_EDITED",
"createdAt": "2024-12-16T09:50:29.775Z",
"data": {
"operation": "UPDATE",
"current": {
"id": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"organizationId": "9864d894-699a-4a00-8d4c-ae181215d721",
"locationId": "27b732ee-5921-475f-acd7-137fc4d5aa0f",
"startAt": "2024-12-16T09:00:00.000Z",
"endAt": "2024-12-16T13:00:00.000Z",
"name": "Task 2",
"assigneeIds": [
"6ad1a95b-ea50-4e23-8495-ef82900ca98d"
],
"recurrenceRule": null
},
"previous": {
"id": "1d63907b-93ed-4188-8b5d-99292fceaae9",
"organizationId": "9864d894-699a-4a00-8d4c-ae181215d721",
"locationId": "27b732ee-5921-475f-acd7-137fc4d5aa0f",
"startAt": "2024-12-16T09:00:00.000Z",
"endAt": "2024-12-16T11:15:00.000Z",
"name": "Task 2",
"assigneeIds": [
"6ad1a95b-ea50-4e23-8495-ef82900ca98d"
],
"recurrenceRule": null
}
},
"id": 201
}

Benefits of TASK_EDITED Webhook

  1. Change Tracking: Provides visibility into what has changed in a task.
  2. Proactive Updates: Notifies systems or users about task modifications in real time.
  3. Audit Capabilities: Enables monitoring of task history and ensures accountability.

By utilizing the TASK_EDITED webhook, organizations can stay updated on task changes and adapt workflows or processes accordingly.